package net.knightwatch.kwtools.customers;

import java.util.ArrayList;

import net.knightwatch.kwtools.walkthrough.Potential;
/**
 * Class for Customer objects.
 * This class is used to outline what a customer is, what they have and what they can do.
 * 
 * @author nsteele
 * @version 05.30.2012
 * @since 1.0
 * 
 */

public class Customer {
	public static final String TAG = "Customer Class";
	// Customers Properties
	private long id; //Primary Key
	private String customerName;
	private ArrayList<Building> buildings;
	private ArrayList<Potential> potentials;

	// Possible implementations
//	private Boolean is_walkthrough_downloaded;
//	private ArrayList<Potential> newPotentials;
	
		
	/**
	 * Default Constructor for the Customer Class
	 * @param customerName of the customer
	 */
	public Customer(){
		this.buildings = new ArrayList<Building>();
		this.potentials = new ArrayList<Potential>();
	}	
	
	/** 
	 * @param building
	 */
	public void addBuilding(Building building){
		this.buildings.add(building);
	}
	
	public String getCustomerName(){
		return this.customerName;
	}
	public void setCustomerName(String name){
		this.customerName = name;
	}
	
	public ArrayList<Building> getBuildingList(){
		// Sort the list by the name and return
		return buildings;
	}
	// Create a single potential for the customer
	public void addPotential(Potential potential){
		this.potentials.add(potential);
	}
	public ArrayList<Potential> getPotentialList(){
		return potentials;
	}
	public void setCustomerId(long id) {
		this.id = id;
	}
	public long getCustomerId(){
		return this.id;
	}

	public void setBuildingList(ArrayList<Building> buildings) {
		// Set the list of buildings for a customer.
		this.buildings = buildings;
	}

	public void setPotentialList(ArrayList<Potential> potentials) {
		// Set the list of potentials for a customer.
		this.potentials = potentials;		
	}
}
